import requestUtils from '@/common/utils/requestUtils.js'
import commonConstants from '@/common/constants/commonConstants.js'
import context from '@/main.js'
import { encrypt} from '@/common/js/des.js'
import store  from "@/store"
// import store from '@/store'
export default {
	/**
	 * 登录
	 */
	doLogin(param, successCallback, errorCallback) {

		var that = this
		var url = commonConstants.request.context.path.auth + "/login/getLogin";
		//var url = commonConstants.request.context.path.message + '/wechat/mini/doLogin';
		var result = requestUtils.getInfoByCondition(url, param, successCallback, errorCallback);
	},
	getMessageListInfoByPager(param, pager, successCallback, errorCallback) {

		let url = commonConstants.request.context.path.message + '/msg/userMessage/getMessageListByPager';
		return requestUtils.getListByPager(url, param, pager, successCallback, errorCallback)
	},
	deleteUserMessageBatchByLogicId(param,successCallback,errorCallback){
		
	  let url = commonConstants.request.context.path.message + '/msg/userMessage/deleteUserMessageBatchByLogicId';
	  
	  return  requestUtils.getListByCondition(url,  param, successCallback,errorCallback)
	},
	updateLogicUserReadStatusBatch(param,successCallback,errorCallback){
		
	  let url = commonConstants.request.context.path.message + '/msg/userMessage/updateUserReadStatusBatch';
	  
	  return  requestUtils.getListByCondition(url,  param, successCallback,errorCallback)
	},
	doBindUserSocialAccount(param,successCallback,errorCallback){
		
	  let url =  commonConstants.request.context.path.wechat + '/wechat/auth/doBindUserSocialAccount';
	  
	  return  requestUtils.getInfoByCondition(url,  param, successCallback,errorCallback)
	},
}
